package com.ss.android.lockscreen.activity.lock;

import android.content.Context;
import android.support.design.a;
import android.support.v4.util.ArrayMap;
import com.ss.android.lockscreen.bb;
import com.ss.android.lockscreen.e.e$c;
import java.util.Map;
import org.json.JSONObject;

import inline.TextDemo;

public final class v implements Runnable {
    private final Context a;

    public v(Context arg1) {
        this.a = arg1;

    }

    public final void run() {
        if(bb.a().d != null) {
            Context v0 = this.a;
            StringBuilder v1 = new StringBuilder("http://open.snssdk.com/data/stream/tt_sl/app_list/v1/?");
            android.support.design.a.a(v1, v0);
            String v0_1 = e$c.a(v1.toString());
            if(TextDemo.c(v0_1)) {
                return;
            }

            try {
                ArrayMap v0_3 = android.support.design.a.a(new JSONObject(v0_1));
                if(v0_3.isEmpty()) {
                    return;
                }

                com.ss.android.lockscreen.aa.a(((Map)v0_3));
                if(com.ss.android.lockscreen.aa.a().get(this.a.getPackageName()) == null) {
                    return;
                }

                bb.a().b();
            }
            catch(Throwable v0_2) {
                v0_2.printStackTrace();
            }
        }
    }
}

